package hotel.base.oversea.utils;

import lombok.*;

import java.io.Serializable;

/**
 * @author zhangjinzheng
 * @date 2019-11-22
 */
@Builder
@ToString
@AllArgsConstructor
public class ResultChannelOrder<T> implements Serializable {

    @Getter
    @Setter
    private Object msg = "success";

    /**
     * 渠道来源 ChannelEnums.ChannelCode  MT(1, "Meituan"), SW(2, "Switchs");
     */
    @Getter
    @Setter
    private int source;

    /**
     * 很好办系统生成的渠道订单id
     */
    @Getter
    @Setter
    private String channelOrderId;

    @Getter
    @Setter
    private T data;

    public ResultChannelOrder() {
        super();
    }

    /**
     *
     * @param msg  错误信息
     * @param code 错误码
     */
    public ResultChannelOrder(String msg,int code){
        super();
        this.msg=msg;
    }
    public ResultChannelOrder(T data, int code) {
        super();
        this.data = data;
    }

}
